// MathieuBC Noel creator
default

     {
    attach(key AvatarKey)//give instructions for use and prevent item from being attached to avatar
{
        if(AvatarKey)
        {//event is called on both attach and detatch, but Key is only valid on attach
            llOwnerSay ("
             ");
            llRequestPermissions(AvatarKey, PERMISSION_ATTACH );
    }}
   
    
  run_time_permissions( integer perm )
    {
   if(perm & PERMISSION_ATTACH)
          {   
             
           llListen( -234111, "", NULL_KEY, "" ); 
         }
   
   }

 
listen( integer channel, string name, key id, string message )
 { 
 
 if ( message == "End" )
    {  
 
          llDetachFromAvatar( );
    
    }}
      }
     

